1. Technical Field
The present invention relates to a system for aiding graphics rendering and, more particularly, to a system for accelerating graphics rendering and compositing in an environment comprising a script language and corresponding engine.
2. Related Art
Devices that display images may be used in many of applications. MP3 players may display images of an artist and/or album artwork associated with its stored media content. Video players may display streaming video from a memory storage device, a private network, and/or the Internet.
Many of these devices provide a user interface to interact with the device. The interface may include a hardwired interface as well as a graphical user interface (GUI). Hardwired interfaces may include pushbutton switches, rotary switches/potentiometers, sliders, and other mechanical based items. Virtual interfaces may be implemented using virtual buttons, virtual sliders, virtual rotator controls, and other display objects. In a combined interface, function identifiers may be generated on a display adjacent to mechanical elements.
The GUI may be implemented using a script application and corresponding virtual machine engine. The virtual machine engine may provide an interface between the script application and the operating system and/or hardware platform of the device. Substantially the same script application or program may be used with different hardware and/or operating system platforms by incorporating a virtual machine engine that may be specific to the hardware and/or operating system of the device.
FLASH® programs may implement GUIs of the foregoing type. The FLASH® environment may include a virtual machine engine, such as a FLASH Player®, that runs a corresponding script application or program. FLASH® may be used to manipulate vector and raster graphics and to support bi-directional streaming of audio and video. The FLASH® environment includes a scripting language called ActionScript®. The FLASH® environment is suitable for use with a wide range of hardware platforms, operating system platforms, and corresponding devices.
Rendering graphics to a display screen using a script application or program and corresponding virtual machine engine may be computationally intensive, particularly when changes to a scene on the display are made in response to a triggering event, such as a user input and/or other event. Scene changes may involve updating the display at frame rates including, but not limited to, thirty frames per second. Each FLASH® frame may be rendered using one or more main processing units.
FLASH® script and virtual machine engines may include multiple objects, some of which are ultimately rendered to a display. Each such object may include other objects and/or graphical primitives, such as rectangles, text, and other primitives. When a change is made to a scene that is presented on the display, affected objects and their graphical primitives may be re-rendered from a back layer to a front-most layer. This repetitive re-rendering of all the affected objects and their graphical primitives may have significant computational costs depending on the size of the affected area, such as the number of pixels that are to be changed. The computational costs may also depend on the number and complexity of the graphic objects within the changed area. In devices having limited processing resources, the rate of the frame updates and/or the processing system operating budget may be exceeded by these re-rendering costs.